Skip to content

Conversation

@petrkonecny2
Copy link
Contributor

@petrkonecny2 petrkonecny2 commented May 12, 2025

Description

This PR aligns the template with latest Expo developments that we had to until now substituted through custom Github Actions.

  1. we are now setting build number from Expo remote config instead of Github variable BUILD_NUMBER that was used for that purpose until now.
  2. we are deprecating and removing copying of Github env variables to eas.json on both build and OTA update in favour of using Expo environment variables.
    By making these changes we want to align more to a standard Expo workflows and remove complexity from our github actions that doesn't have to be there.

There is a mapping that should be just temporary until we fully align our environment names. For now all github actions environment names are mapped from our names to EAS names, dev -> development, staging -> preview, production -> production. This is done automatically in build and update actions. Just keep this in mind when you are setting environment variables directly in EAS dashboard.

How to migrate:

  • copy over all contents of .github/actions and .github/workflows folder from the template into your project
  • BUILD NUMBER SETUP
    • make sure that the BUILD_NUMBER env variable in your projects Github repo is synced with the remote value in Expo for both staging and production profiles. This is done through eas build:version:set --profile command.
    • delete buildNumber and all of its uses from app.config.ts.
    • make sure that in eas.json "autoIncrement": true is set for staging and production
  • ENV VARIABLES SETUP
    • make sure your env variables from Github are synced with your EAS dashboard, you can do this either through the EAS dashboard UI or through the CLI.
    • set correct environment in your eas.json. You can look into the template for reference.

Related Tickets/Issues

Petr Konecny added 2 commits May 14, 2025 16:49
@petrkonecny2 petrkonecny2 changed the title chore: deprecated github env variables and github build number chore: switched to expo env variables and build number May 14, 2025
"autoIncrement": true,
"environment": "preview"
},
"production": {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we "autoIncrement": true, for production as well?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are right. Initially I though that it has one build number for all profiles but after some testing it seems that it is separate for each.

@petrkonecny2 petrkonecny2 merged commit c68264e into main May 15, 2025
1 check passed
@petrkonecny2 petrkonecny2 deleted the chore/update-actions branch May 15, 2025 09:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants